module.exports = (app) => {
  const DataTypes = app.Sequelize;
  return app.model.define('t_realdata_accctrl', {
    rd_updatetime: {
      type: DataTypes.DATE,
      allowNull: false,
      defaultValue: "2019-11-28 00:00:00"
    },
    pdi_index: {
      type: DataTypes.INTEGER.UNSIGNED,
      allowNull: false,
      defaultValue: 0
    },
    rd_CurJobNum: {
      type: DataTypes.FLOAT(9,2),
      allowNull: true,
      defaultValue: 0.00
    },
    rd_NetCom: {
      type: DataTypes.TINYINT,
      allowNull: true,
      defaultValue: 0
    }
  }, {
    tableName: 't_realdata_AccCtrl',
    timestamps: false,
    underscored: false,
    indexes: [
      {
        name: "pdi_index",
        unique: true,
        using: "HASH",
        fields: [
          { name: "pdi_index" },
        ]
      },
    ]
  });
};
